﻿#include "a_class.h"

//about a_class
//alex

bool a_class::b_flag=false;

point2d a_class::add(const point2d& a,const point2d& b)
{
	point2d temp;
	temp.x=a.x+b.x;
	temp.y=a.y+b.y;
	return temp;
}


extern int sub(const int a,const int b);
point2d a_class::sub(const point2d& a, const point2d& b)
{
	point2d temp;
	temp.x=::sub(a.x,b.x);
	temp.y=::sub(a.y,b.y);
	
	return temp;
}

point2d a_class::mul(const point2d& a,const point2d& b)
{
	point2d temp={0,0};
	temp.x=a.x*b.x; 
	if (a_class::b_flag==false) {temp.y=a.y*b.y;}
	return temp;
}

point2d a_class::mul(point2d& a, point2d& b)
{
	point2d temp={0,0};
	temp.x=a.x*b.x; 
	if (a_class::b_flag==false) {temp.y=a.y*b.y;}
	return temp;
}

